﻿<!DOCTYPE html>
<html lang="en">
<#include "../include/resource-head.ftl"/>
<#assign active='siteAdd'/>
<body>
<#include "../include/common-top.ftl"/>
<div class="main-container" id="main-container">
    <div class="main-container-inner">
    <#include "../include/common-menu.ftl"/>
        <div class="main-content">
            <div class="page-content">
                <div class="col-xs-12">
                    <div class="row-fluid">
                        <div class="widget-box">
                            <div class="widget-header widget-header-blue widget-header-flat">
                                <h4 class="lighter">
                                    <i class="icon-plus"></i>房屋详情
                                </h4>
                            </div>
                            <div class="widget-body">
                                <div class="widget-main">
                                    <div class="step-content row-fluid position-relative">
                                        <form class="form-horizontal" action="/admin/house/update" method="post">
                                            <input name="id" value="${house.id}" type="hidden">

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">标题</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="text" class="width-100" name="title"
                                                           value="${house.title!}"/>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">地址</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="text" class="width-100" name="address" value="${house.address!}"/>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">小区</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="text" class="width-100" name="estate" value="${house.estate!}" required/>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">房屋类型</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="text" class="width-100" name="style" value="${house.style!}" required placeholder="几室几厅"/>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">楼层类型</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="text" class="width-100" name="floor" value="${house.floor!}" required placeholder="5层/19层"/>
                                                </div>
                                            </div>


                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">联系方式</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="text" class="width-100" name="phone" value="${house.phone!}"/>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">价钱（元）</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <input type="number" class="width-100" name="money" value="${house.money?string("#")}"/>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">类型</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <select class="width-100" name="type" >
                                                        <option value="出租" <#if house.type =='出租'>selected</#if> >出租</option>
                                                        <option value="出售" <#if house.type =='出售'>selected</#if>>出售</option>
                                                        <option value="求租" <#if house.type =='求租'>selected</#if>>求租</option>
                                                        <option value="求售" <#if house.type =='求售'>selected</#if>>求售</option>
                                                    </select>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">装修</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <select class="width-100" name="fitup">
                                                        <option value="毛坯" <#if house.fitup =='毛坯'>selected</#if>>毛坯</option>
                                                        <option value="简单装修" <#if house.fitup =='简单装修'>selected</#if>>简单装修</option>
                                                        <option value="中等装修" <#if house.fitup =='中等装修'>selected</#if>>中等装修</option>
                                                        <option value="精装修" <#if house.fitup =='精装修'>selected</#if>>精装修</option>
                                                        <option value="豪华装修" <#if house.fitup =='豪华装修'>selected</#if>>豪华装修</option>
                                                    </select>
                                                </div>
                                            </div>

                                            <div class="form-group has-info">
                                                <label class="col-xs-12 col-sm-3 control-label no-padding-right">车位</label>
                                                <div class="col-xs-12 col-sm-5">
                                                    <select class="width-100" name="car">
                                                        <option value="有" <#if house.car =='有'>selected</#if>>有</option>
                                                        <option value="无" <#if house.car =='无'>selected</#if>>无</option>
                                                    </select>
                                                </div>
                                            </div>


                                            <div class="form-group has-info">
                                                <div class="col-xs-1"></div>
                                                <div class="col-xs-12 col-sm-10">
                                                    <textarea id="editor" name="content"
                                                              style="width: 100%;">${house.content!}</textarea>
                                                </div>
                                            </div>
                                            <hr/>
                                            <div class="row-fluid wizard-actions">
                                                <button class="btn" type="reset">重置</button>
                                                <button class="btn btn-success" type="submit">提交</button>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div><!-- /.page-content -->
        </div><!-- /.main-content -->
    </div><!-- /.main-container -->
</body>
<#include "../include/resource-script.ftl"/>
<script type="text/javascript">
    KindEditor.ready(function (K) {
        window.editor = K.create('#editor', {
            uploadJson: '/uploadFile',
            fileManagerJson: '',
            allowFileManager: false
        });
    });
</script>
</html>

